package com.senlingspace.web.controller.system;

import com.senlingspace.common.core.controller.BaseController;
import com.senlingspace.common.core.page.TableDataInfo;
import com.senlingspace.system.domain.SysCounty;
import com.senlingspace.system.service.ISysCountyService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;

import java.util.List;

/**
 * 区县信息Controller
 * 
 * @author wangliang
 * @date 2024-07-01
 */
@RestController
@RequestMapping("/system/county")
public class SysCountyController extends BaseController {
    @Autowired
    private ISysCountyService sysCountyService;

    /**
     * 查询区县信息列表
     */
//    @PreAuthorize("@ss.hasPermi('system:county:list')")
    @GetMapping("/list")
    public TableDataInfo list(String cityCode) {
        List<SysCounty> list = sysCountyService.selectSysCountyList(cityCode);
        return getDataTable(list);
    }


}
